MOOC Utils

Utils like auto assignment solver extension and course notice announcment notification for MOOC courses

Landing page components

Introduction#

Marketing page sections: Hero, Features, ProductShowcase, FAQ, and Footer. How they sit together on the home route.

Project structure#

The landing page components are organized within the website application under the components/landing directory. They are exported via a centralized index file and consumed by the main page component.

Core components#

The landing page is composed of five distinct components, each serving a specific role in the user journey:

Hero component#

The Hero component is the primary value proposition display, featuring:

  • Full-screen hero section with animated background elements
  • Dual-column layout (text + visual mockup) that adapts responsively
  • Interactive download call-to-action with hover animations
  • Statistics display highlighting platform achievements
  • Browser mockup showing real assignment solving interface
  • Coming-soon indicator for Notice Reminders feature

Features component#

The Features component shows platform capabilities through:

  • Two-column feature grid (Assignment Solver active, Notice Reminders coming soon)
  • Icon-based feature cards with hover effects
  • Animated entrance transitions for feature cards
  • Clear status indicators for feature availability
  • Consistent design language with color-coded accents

Product showcase#

ProductShowcase presents the two core tools through:

  • Card-based layout with hover effects and shadow transitions
  • Feature comparison between active and upcoming products
  • Status indicators (Active vs. Coming Soon)
  • Prominent call-to-action buttons for each product
  • Visual differentiation through color schemes and accents

FAQ component#

The FAQ component provides:

  • Interactive accordion-style question-answer sections
  • Smooth expand/collapse animations using CSS grid transitions
  • State management for controlling open/close states
  • Responsive design that works across device sizes
  • Consistent styling with the overall design system

The Footer provides:

  • Multi-column navigation structure (Brand, Products, Resources, Community, Legal)
  • Social media and GitHub integration
  • Copyright and attribution information
  • Consistent typography and spacing
  • Accessible navigation links

Architecture overview#

The landing page follows a component-based architecture and reusable design patterns.

The architecture uses:

  • Component Composition: Each component is self-contained with its own styling and logic
  • Design System Integration: Consistent use of shadcn/ui primitives and Tailwind CSS
  • Responsive Design Patterns: Mobile-first approach with progressive improvement
  • State Management: Local component state for interactive elements (FAQ accordion)
  • Accessibility: Semantic HTML and proper ARIA attributes

Detailed component analysis#

Hero component analysis#

The Hero component implements a detailed full-screen hero section with multiple visual and interactive elements.

Key implementation patterns:

  • CSS Grid Layout: Responsive two-column layout using grid and lg:grid-cols-[1fr_1.15fr]
  • Animation System: Staggered entrance animations using CSS classes and delays
  • Background Effects: Radial gradients, dot grid patterns, and blur effects
  • Interactive Elements: Hover animations on CTA buttons with arrow icons
  • Status Indicators: “Coming Soon” badges with visual styling

Responsive design implementation:

  • Mobile-first approach with sm: and lg: breakpoints
  • Flexible typography using clamp() for fluid scaling
  • Hidden elements on smaller screens (hidden lg:block)
  • Animated entrance sequences with staggered timing

Features component analysis#

The Features component presents platform capabilities through a structured grid layout.

Implementation patterns:

  • Data-driven Content: Feature arrays for Assignment Solver and Notice Reminders
  • Conditional Rendering: Different treatment based on feature availability
  • Status Indicators: Color-coded badges for feature states
  • Hover Effects: Interactive cards with border and background transitions
  • Animation System: Staggered entrance animations for feature cards

Content management approach:

  • Features are defined as arrays of objects with icon, title, and description
  • Separate arrays for active and upcoming features
  • Consistent structure allows easy modification and expansion

Product showcase analysis#

ProductShowcase splits the two tools into distinct cards.

Key features:

  • Visual Hierarchy: Clear distinction between active and upcoming products
  • Status Communication: Diagonal ribbons and grayscale effects
  • Feature Comparison: Side-by-side presentation of capabilities
  • Call-to-Action Focus: Prominent buttons directing users to tools
  • Hover Interactions: Shadow and border transitions for improved UX

FAQ component analysis#

The FAQ component implements an interactive accordion system for frequently asked questions.

Implementation details:

  • State Management: Uses React useState hook for managing open/close state
  • CSS Grid Transitions: grid-rows-[1fr] and grid-rows-[0fr] for smooth animations
  • Conditional Styling: Dynamic class names based on open state
  • Accessible Interactions: Proper button semantics and keyboard navigation
  • Responsive Design: Works across mobile and desktop devices

The Footer component provides detailed navigation and legal information.

Structure and organization:

  • Multi-column Grid: Responsive grid layout adapting to screen size
  • Logical Grouping: Related links grouped by category
  • Consistent Styling: Uniform typography and spacing
  • External Links: Proper handling of external resources with security attributes
  • Legal Compliance: Privacy policy and copyright information

Dependency analysis#

Landing sections share the same providers and styling primitives, so spacing and CTAs stay consistent.

Key dependency patterns:

  • Utility Function Sharing: All components use the cn function for conditional class merging
  • Design System Integration: Consistent use of shadcn/ui button variants
  • Icon System: Universal Lucide React icon library for visual consistency
  • Routing Integration: Next.js Link components for smooth navigation
  • Theme System: Shared Tailwind CSS variables and color schemes

Performance considerations#

The landing page components are designed with performance optimization in mind:

Rendering optimizations#

  • Component Isolation: Each component manages its own state and rendering logic
  • Minimal Re-renders: Local state only affects specific component areas
  • CSS Animations: Hardware-accelerated transitions using transform properties
  • Lazy Loading: Images and visual elements load progressively

Bundle size management#

  • Tree Shaking: Unused code eliminated through proper module exports
  • Icon Optimization: Lucide React icons loaded as individual SVG components
  • CSS Optimization: Tailwind CSS purged to remove unused styles
  • Image Optimization: Next.js automatic image optimization

Accessibility features#

  • Semantic HTML: Proper heading hierarchy and landmark roles
  • Keyboard Navigation: Full keyboard accessibility for interactive elements
  • Screen Reader Support: ARIA attributes and proper labeling
  • Color Contrast: WCAG-compliant color schemes and contrast ratios

Troubleshooting guide#

Common issues and solutions#

Component Not Rendering

  • Verify component export/import statements in the index file
  • Check for proper TypeScript syntax and JSX formatting
  • Ensure all required dependencies are installed

Styling Issues

  • Confirm Tailwind CSS configuration includes the components directory
  • Verify CSS custom properties are properly defined in globals.css
  • Check for conflicting CSS classes or specificity issues

Animation Problems

  • Ensure CSS animations are enabled in the browser
  • Verify animation classes are properly applied
  • Check for CSS transitions conflicts

Responsive Design Issues

  • Test component layouts across different viewport sizes
  • Verify breakpoint configurations match design requirements
  • Check for proper mobile-first CSS declarations

SEO Optimization

  • Verify meta tags are properly configured in layout.tsx
  • Ensure robots.txt and sitemap.ts are correctly set up
  • Test SEO using tools like Google Search Console

Conclusion#

Hero sells the problem, Features and ProductShowcase show the tools, FAQ handles objections, Footer carries links. Keep analytics hooks on the CTAs.